function [x,y,typ]=SRRCF_int(job,arg1,arg2)
   x=[];y=[];typ=[]
   
   select job
		case 'plot' then
  			standard_draw(arg1)
		case 'getinputs' then
  			[x,y,typ]=standard_inputs(arg1)
		case 'getoutputs' then
  			[x,y,typ]=standard_outputs(arg1)
		case 'getorigin' then
  			[x,y]=standard_origin(arg1)
  		case 'set' then
		       //set the parameters of the SRRCF
		    x=arg1;
		    graphics=arg1.graphics;model=arg1.model;
			exprs=graphics.exprs;
			
			while %t do
			 //get parameters
			 [ok,dt,L,M,alpha,exprs]=getvalue('set block parameters',...
			 ['interval between samples';...
			 'samples per symbol';...
			 'the number of symbols';...
			 'roll-off factor';],...
			 list('vec',1,'vec',1,'vec',1,'vec',1),exprs)
			 
			 if ~ok then break,end;
			   
			   //check validity of parameters
			 if(alpha>1) | (alpha<0) then
			     message('roll-off factor must between 0 and 1')
			     ok=%f;
		     end
			   			   
			   //write back parameters
			 if ok then
			     graphics.exprs=exprs
			     model.in=L*M;
			     model.out=L*M;
			     model.rpar=[dt,L,M,alpha];
			     model.dstate=zeros(L*M,1);
			     x.graphics=graphics;x.model=model;
			     break;
	         end
       end
        case 'define' then
	        dt=0.01;
	        L=32;
	        M=16;
	        alpha=0.5;
	        exprs=[string(dt),string(L),string(M),string(alpha)];
	        model=scicos_model();
	        model.sim=list('SRRCF_com',5)
	        model.in=L*M;
	        model.out=L*M;
	        model.rpar=[dt,L,M,alpha];
	        model.dstate=zeros(L*M,1);
	        model.blocktype='d'
	        model.dep_ut=[%f %t]
	        gr_i=['xstringb(orig(1),orig(2),[''SRRCF''],sz(1),sz(2),''fill'')']
	        x=standard_define([2.5 2.5],model,exprs,gr_i)
			end
  	
endfunction
